package com.medical.track.service.impl;

import com.medical.track.mapper.DoctorMapper;
import com.medical.track.model.Doctor;
import com.medical.track.service.DoctorService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

@Service("doctorService")
public class DoctorServiceImpl implements DoctorService{
    @Autowired
    private DoctorMapper doctorMapper;

    @Override
    public void deleteDoctor(String user_id) {
        Doctor exit = doctorMapper.selectByUserId(user_id);
        if(exit!=null){
            doctorMapper.deleteByPrimaryKey(user_id);
        }
    }
}
